<!-- 我的单个 -->

<template>
  <div>
    <div>
      <span>待选择{{ CORE.MAP.ASSET }} ({{ model.id ? 1 : 0 }}/{{ list.length }})</span>
      <span class="floatRight">共 {{ total }} 个</span>
    </div>

    <el-input
      v-model="param.assetName"
      suffix-icon="el-icon-search"
      :placeholder="`${CORE.MAP.ASSET}名称`"
      clearable
      @change="toSearch"
    />

    <WebTable v-bind="tableProps" @select="toSelect">
      <RowCheckbox :disabled="info.disabled" :grayed="info.grayed" />
      <RowText :label="`${CORE.MAP.ASSET}名称`" bind="assetName" :minWidth="100" left />
      <RowTree :label="`${CORE.MAP.ASSET}分类`" bind="assetTypeId" :dict="category_treeDict" left />
    </WebTable>
  </div>
</template>

<script>
// ============================== 导入依赖 ============================== //

import CORE from '@/CORE'
import mixSingle from '@admin/components/choose/mixSingle'

// ============================== 导出组件 ============================== //

export default {
  /**
   * 名称定义 (实际使用名称)
   */
  name: 'MySingle',

  /**
   * 混入列表 (配置选项合并)
   */
  mixins: [mixSingle, CORE.mixTree('category', 'category_')],
}
</script>
